package com.alks.function.controller.procurement;


import com.alks.common.aop.ApiRestController;
import com.alks.common.aop.WebLogger;
import com.alks.entity.data.response.ResponseInfo;
import com.alks.function.controller.task.OrderUsageDiffTask;
import com.alks.function.service.procurement.BrandMaterialDefinitionService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;

@ApiRestController("/ProcurementWarning")
@Slf4j
@Api(tags = {"采购部-预警"})
//@RoleCheck(prgIds = {"150106"},methodName = "getBrandTypeList")
public class WarningController {

    @Autowired
    private OrderUsageDiffTask orderUsageDiffTask;

    @WebLogger
    @GetMapping("/updateOrderUsageDiff")
    @ApiOperation(value = "更新采购单耗差异数据",tags = "采购部-预警")
    public ResponseInfo updateOrderUsageDiff(){
        orderUsageDiffTask.ScheduleGetOrderUsageDiff();
        return ResponseInfo.ok();
    }
}
